﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<Gola.VN.Scb.Web.Common.PaginatedList<Gola.VN.Scb.Web.Common.Entities.ProductEntity>>" %>
<%@ Import Namespace="Gola.VN.Scb.Web.Presentation.Helpers" %>
<div class="divpaging clfix">
    <ul class="listpaging">
        <% if (Model.HasPreviousPage)
           {%>
        <li><a href="<%: Url.RouteUrl("displayProducts", new  {id=Model[0].CategoryId , queryvalues =( ViewData["QueryValue"].ToString() + "/p-"+(Model.PageIndex-1))}) %>"
            title="Trước">&lt;&lt;Trước</a></li><%
           }%>
        <%  for (var i = Model.PageIndexDisplayStart; i < Model.PageIndexDisplayTotal; i++)
            {%>
        <li <%if(i==Model.PageIndex)
{%>class="active" <%
}%>><a href="<%: Url.RouteUrl("displayProducts", new  {id=Model[0].CategoryId , queryvalues =(ViewData["QueryValue"].ToString() +"/p-"+i)}) %>"
    title="<%:  i.ToPageDisplay() %> ">
    <%: i %></a></li>
        <%}%>
        <% if (Model.HasNextPage)
           {%>
        <li><a href="<%: Url.RouteUrl("displayProducts", new  {id=Model[0].CategoryId , queryvalues =(ViewData["QueryValue"].ToString() +"/p-"+(Model.PageIndex+1))}) %>"
            title="Tiếp">Tiếp &gt;&gt;</a></li><%
           }%>
    </ul>
    &nbsp;&nbsp;<span>Chuyển nhanh:</span>
    <%:Html.DropDownList("QuickIndex", Model.PageIndexs)%>
</div>
